import request from '@/utils/request'

export function fetchList(query) {
  return request({
    url: '/vms/v1/video/list',
    method: 'get',
    params: query
  })
}

export function getVideoToken(query) {
  return request({
    url: '/vms/v1/video/upToken',
    method: 'get',
    params: query
  })
}

export function addVideo(data) {
  return request({
    url: '/vms/v1/video/save',
    method: 'post',
    data
  })
}

export function setVideoPfop(data) {
  return request({
    url: '/vms/v1/video/pfop',
    method: 'post',
    data
  })
}

export function getVideoPfopStatus(query) {
  return request({
    url: '/vms/v1/video/pfop/status',
    method: 'get',
    params: query
  })
}
